package net.pm.core.entities.db;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

import net.pm.core.entities.PMCommandEntity;


/**
 * The persistent class for the district database table.
 * 
 */
@Entity
@Table(name="district")
public class District extends PMCommandEntity<District> {
	/**
	 * 
	 */
	private static final long serialVersionUID = 7783217027301220069L;
	private Integer id;
	private String cityCode;
	private String code;
	private String name;

    public District() {
    }
    
    

	public District(Integer id) {
		super();
		this.id = id;
	}



	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	@Column(unique=true, nullable=false)
	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}


	@Column(nullable=false, length=6)
	public String getCityCode() {
		return this.cityCode;
	}

	public void setCityCode(String cityCode) {
		this.cityCode = cityCode;
	}


	@Column(nullable=false, length=6)
	public String getCode() {
		return this.code;
	}

	public void setCode(String code) {
		this.code = code;
	}


	@Column(nullable=false, length=15)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Override
	public int compareTo(District o) {
		// TODO Auto-generated method stub
		return 0;
	}
	
}